#pragma once
#include <QStandardItemModel>
#include <vector>
#include <QDir>
class FileSystemModal :
	public QStandardItemModel
{
public:
	FileSystemModal(void);
	~FileSystemModal(void);

	virtual QVariant data(const QModelIndex & index, int role) const;
	void setCurrentPath(const QString& path);
	QString getCurrentPath();
	void setIsTravelDeep(bool isdeep);
	bool isTravelDeep();
	virtual bool removeRows(int row, int count, const QModelIndex &parent  = QModelIndex() );
private:
	void fillData();
	void travelFolder(const QString& dir,std::vector<QFileInfo>& fileInfos,bool bDeep);
	QString cur_path_;
	std::vector<QFileInfo> data_;
	bool  deep_;
};

	